<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<body>
    <div th:fragment="addFrag">
            <form id="addForm" method="post" class="easyui-form">
                <table cellpadding="5" align="center">
                    <tr>
                        <td>父节点:</td>
                        <td>
                            <input type="hidden" name="parentId"/>
                            <input class="easyui-validatebox" type="text" style="width: 200px" name="parentNodeName" disabled="disabled"/>
                        </td>
                    </tr>
                    <tr>
                        <td>名称:</td>
                        <td><input class="easyui-validatebox" type="text" style="width: 200px" name="name" data-options="required:true,validType:'maxLength[30]'"/></td>
                    </tr>
                    <tr>
                        <td>类型:</td>
                        <td>
                            <select class="easyui-combobox" name="resType" style="width:80px" data-options="editable:false,panelHeight:'auto',onChange:function(n,o){resTypeChange(n,o,'addForm');}">
                                <option value="AUTH" selected="selected">权限</option>
                                <option value="API" >API</option>
                                <option value="MENU">子菜单</option>
                                <option value="FOLDER">菜单夹</option>
                            </select>
                        </td>
                    </tr>
                    <tr>
                        <td>URL:</td>
                        <td><input class="easyui-validatebox" type="text" style="width: 200px" name="url" data-options="required:false,disabled:true,validType:'maxLength[60]'"/></td>
                    </tr>
                    <tr>
                        <td>权限标识:</td>
                        <td><input class="easyui-validatebox" type="text" style="width: 200px" name="permission" data-options="required:true,validType:'maxLength[40]'"/></td>
                    </tr>
                    <tr style="display: none" id="selectIconRow">
                        <td>图标:</td>
                        <td>
                            <div style="float: left;padding-top: 3px">
                                <img src="" id="img_icon" style="display: none"/>
                            </div>
                            <div style="float: right">
                            <input class="easyui-searchbox" style="width:150px" name="icon" id="searchbox_icon"
                                   data-options="editable:false,required:false,searcher:selectIcon,prompt:'请选择一个图标'"/>
                            </div>
                        </td>
                    </tr>
                    <tr>
                        <td>排序:</td>
                        <td>
                            <input class="easyui-numberspinner" style="width:80px;" value="1" name="seq" data-options="required:true,min:1,max:100,editable:true"/>
                        </td>
                    </tr>
                    <tr>
                        <td>请求方式:</td>
                        <td>
                            <select class="easyui-combobox" name="method" style="width:80px" data-options="editable:false,panelHeight:'auto'">
                                <option value="NONE" selected="selected">-----</option>
                                <option value="GET">GET</option>
                                <option value="POST">POST</option>
                            </select>
                        </td>
                    </tr>

                    <tr>
                        <td>状态:</td>
                        <td>
                            <select class="easyui-combobox" name="state" style="width:80px" data-options="editable:false,panelHeight:'auto'">
                                <option value="1" selected="selected">启用</option>
                                <option value="0">禁用</option>
                            </select>
                        </td>
                    </tr>
                </table>
            </form>
    </div>
</body>
</html>